<%@ page pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <title>唯星集团</title>
    <meta name="keywords" content="唯星集团">
    <meta name="description" content="唯星集团">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <link rel="shortcut icon" href="images/favicon.ico">
    <link rel="stylesheet" href="layui/css/layui.css"  media="all">
    <<script src="layui/layui.js" charset="utf-8"></script>
    <!-- include main css -->
    <link rel="stylesheet" type="text/css" href="css/slick.css"/>
    <link rel="stylesheet" type="text/css" href="css/bootstrap.css"/>
    <link rel="stylesheet" type="text/css" href="css/jquery.mmenu.all.css"/>
    <link rel="stylesheet" type="text/css" href="css/style.css"/>
    <link href="font-awesome-4.5.0/css/font-awesome.min.css" rel='stylesheet' type='text/css' media="all" />
    <link rel="stylesheet" type="text/css" href="css/animate.css"/>
    <script src="js/jquery.min.js"></script>

</head>
<body >
<header class="header">
    <div class="container clearfix">
        <div class="logo">
            <a href="index.html"><!--<img src="images/logo.png" alt="" />--><h1>Hello</h1></a>
        </div>
        <div class="nav_right">
            <nav>
                <ul class="clearfix">
                    <li><a href="index.html">首页</a></li>
                    <li><a href="case.html">挑选爱犬</a>
                        <ul>
                            <li><a href="case.html">小型犬</a></li>
                            <li><a href="case.html">中型犬</a></li>
                            <li><a href="case.html">大型犬</a></li>
                        </ul>
                    </li>
                    <li><a href="kehu.html">狗狗周边</a>
                        <ul>
                            <li><a href="kehu.html">北京</a></li>
                            <li><a href="kehu.html">上海</a></li>
                            <li><a href="kehu.html">天津</a></li>
                        </ul>
                    </li>
                    <li><a href="fuwu_price.html">寻找另一半</a></li>
                    <li><a href="about.jsp" class="active">个人中心</a>
                        <ul>
                            <li><a href="about.jsp">公司简介</a></li>
                            <li><a href="about_fuwu.html">我们的服务</a></li>
                            <li><a href="about_wh.html">企业文化</a></li>
                        </ul>
                    </li>
                    <li><a href="team.html">购物车</a>
                        <ul>
                            <li><a href="team.html">北京</a></li>
                            <li><a href="team.html">上海</a></li>
                            <li><a href="team.html">天津</a></li>
                        </ul>
                    </li>

                    <li><a href="news.html">新闻资讯</a>
                        <ul>
                            <li><a href="news.html">最新优惠</a></li>
                            <li><a href="news.html">公司新闻</a></li>
                            <li><a href="news.html">行业新闻</a></li>
                        </ul>
                    </li>
                    <li><a href="contact.html">联系我们</a>
                        <ul>
                            <li><a href="contact.html">联系我们</a></li>
                            <li><a href="feedback.html">在线留言</a></li>
                        </ul>
                    </li>
                </ul>
            </nav>
            <div class="cen">
                <a href="">CN</a>
                <a href="">EN</a>
            </div>
        </div>


        <a href="#mmenu" class="phone-nav"><i class="fa fa-list"></i></a>

    </div>
</header>
<div class="crumbs">
    <div class="centerBlock">您当前的位置：<a href="index.html">首页 </a>  > <span>个人中心</span></div>
</div>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>

<div class="content" style="height: 1000px; width: 70%;margin: auto;">


    <div class="comon_top">
        <div class="top_nav">
            <a href="mycenter" ><span>个人信息</span></a><a href="sellDog" class="active"><span>我要卖狗狗</span></a><a href="shouchang"  ><span>我的收藏</span></a>
            <a href="about"  ><span>我的购物车</span></a><a href="dizhi"><span>地址管理</span></a><a href="uppwd"><span>修改密码</span></a>
        </div>
    </div>
    <hr>
    <div class="comon_top">
        <div class="top_title">
            <div class="hh1">请修改商品信息</div>
            <div class="hh2">请提供准确无误的商品信息，否则商品无法通过审核并且影响您的信用等级！</div>
            <div class="hh3">To provide a comfortable home environment for you,Promote high quality of life, improve the industry standard!</div>
        </div>
    </div>

    <form action="sellDogInfo"  method="get"  enctype="multipart/form-data">
        <input type="hidden" name="userId" VALUE="${user.userId}">
        <div class="layui-form-item">

            <div class="layui-input-inline" style="margin-left: 100px">
                <select name="leixing" style="margin-left: 50px;width: 200px;height: 30px;">
                    <option value="">类型</option>
                    <option value="大型犬"  <c:if test="${item.dogType eq '大型犬'}">selected="selected"</c:if> >大型犬</option>
                    <option value="中型犬"  <c:if test="${item.dogType=='中型犬'}">selected</c:if> >中型犬</option>
                    <option value="小型犬">小型犬</option>

                </select>
            </div>
            <div class="layui-input-inline">
                <select name="pingzhong" style="margin-left: 50px;width: 200px;height: 30px;">
                    <option value="">品种</option>
                    <option value="藏獒">藏獒</option>
                    <option value="秋田犬">秋田犬</option>
                    <option value="阿拉斯加">阿拉斯加</option>
                </select>
            </div>

        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">价格</label>
            <div class="layui-input-block">
                <input type="number" max="100000" min="100" name="price" lay-verify="title" autocomplete="off" placeholder="请输入价格" class="layui-input">
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">年龄</label>
            <div class="layui-input-block">
                <input type="number" max="10" min="0" name="age" lay-verify="title" autocomplete="off" placeholder="请输入年龄" class="layui-input">
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">性别</label>
            <div class="layui-input-block">
                <select name="sex" lay-filter="aihao">
                    <option value="公">公</option>
                    <option value="母">母</option>
                </select>
            </div>
        </div>


        <div class="layui-form-item layui-form-text">
            <label class="layui-form-label">描述:</label>
            <div class="layui-input-block">
                <textarea placeholder="请输入内容" name="info" class="layui-textarea"></textarea>
            </div>
        </div>
        <br>
        <br>










        <button class="layui-btn layui-btn-lg layui-btn-normal">确认提交</button>
        <p style="color: red">${infos}</p>


    </form>
</div>
</body>


<script>


    layui.use(['form','layer','table','upload','layedit', 'laydate'], function(){
        var table = layui.table
            ,form = layui.form
            ,upload = layui.upload
            ,$=layui.$
            ,layer = layui.layer
            ,layedit = layui.layedit
            ,laydate = layui.laydate;


        var uploadInst = upload.render({
            elem: '#test1'
            ,url: 'upload?id='+${user.userId}
            ,before: function(obj){
                //预读本地文件示例，不支持ie8
                obj.preview(function(index, file, result){
                    $('#demo1').attr('src', result); //图片链接（base64）
                });
            }
            ,done: function(res){
                //如果上传失败
                if(res.code > 0){//自定义返回失败
                    return layer.msg('上传失败');
                }else{
                    $('#pic').val(res.img);
                }
                //上传成功
            }


        });
        //日期
        laydate.render({
            elem: '#date'
        });
        laydate.render({
            elem: '#date1'
        });

        //创建一个编辑器
        var editIndex = layedit.build('LAY_demo_editor');

        //自定义验证规则
        form.verify({
            title: function(value){
                if(value.length < 5){
                    return '标题至少得5个字符啊';
                }
            }
            ,pass: [/(.+){6,12}$/, '密码必须6到12位']
            ,content: function(value){
                layedit.sync(editIndex);
            }
        });

        //监听指定开关
        form.on('switch(switchTest)', function(data){
            layer.msg('开关checked：'+ (this.checked ? 'true' : 'false'), {
                offset: '6px'
            });
            layer.tips('温馨提示：请注意开关状态的文字可以随意定义，而不仅仅是ON|OFF', data.othis)
        });

        //监听提交
        form.on('submit(demo1)', function(data){
            layer.alert(JSON.stringify(data.field), {
                title: '最终的提交信息'
            })
            return false;
        });



    })

</script>



</html>
